﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="NewLetter_Emails.ascx.cs" Inherits="Web.Cms.NewsLetter_Emails.NewLetter_Emails" %>
<%@ Register TagPrefix="uc1" TagName="PagingAjax" Src="~/Cms/AjaxCP/Paging.ascx" %>
 <script type="text/javascript">
     $(document).ready(function () {
         $("#<%=txtKeysearch.ClientID%>").autocomplete('/Layout/AutoComplateSearch/TimTheoTenBaiHat.ashx');
     });       
</script>-
<%--<script type="text/javascript">
    $(function () {
        $("#<%=txtDatefrom.ClientID %>").datepicker({ showOn: 'button', buttonImage: '/images/calendar_1.gif', buttonImageOnly: true });
        $("#<%=txtDateTo.ClientID %>").datepicker({ showOn: 'button', buttonImage: '/images/calendar_1.gif', buttonImageOnly: true });
    });
</script>--%>

<div id="uc_CMSContents">
<div class="fl">
     <a style="cursor:hand;" href="javascript:void(0)" onclick="javascript:return showPopWinADMIN('/Cms/NewsLetter_Emails/NewsLetter_Emails.aspx','Thêm Mới FQA',500,400,null,__doPostBack)">
        <img src="/App_Themes/Default/Images/Add_b.gif" border="0" />
    </a>  
</div>
<div style="padding-bottom: 20px;" class="fl">
<p class="heading" style="margin-left:400px"><asp:Label runat="server" ID="lbHeader" Text="Danh Sách Nhận Mail Khuyến Mại"></asp:Label></p>        
</div>
<div class="clear8px"></div>
<div style="margin-left:250px">   
    <%--<div style="float:left;padding-right:10px;padding-left:10px;"><b>Tìm Kiếm :</b> <asp:TextBox runat="server" ID="txtKeysearch" Height="18" Width="225"></asp:TextBox></div>--%>
    <div style="clear:both;padding-top:5px;"></div>
    <div style="float:left;padding-right:10px;padding-left:10px;"><b>Tên </b> <asp:textbox CssClass="input-txt" id="txtKeysearch" runat="server" Height="18px" Width="150"></asp:textbox></div>        
    <div style="float:left;padding-right:10px;padding-left:112px;"><b>Nhóm Khuyến Mại</b>
            <asp:DropDownList ID="dropGroup" runat="server" Height="20px">
                <asp:ListItem Value="0">--Lựa chọn--</asp:ListItem>
                <asp:ListItem Value="1">Nhóm khuyến mại</asp:ListItem>
                <asp:ListItem Value="2">Nhóm quảng cáo</asp:ListItem>
            </asp:DropDownList>
    </div>    
    <div style="float:left;padding-right:10px;padding-left:20px;"><asp:Button runat="server" ID="btnTimKiem" CssClass="Button_Search" onclick="btnTimKiem_Click"/></div>
</div>
<div style="clear:both;"><asp:Label Font-Bold="true" ForeColor="red" Font-Size="11px" ID="lblMessage" runat="server"></asp:Label></div>

<br />

<asp:GridView ID="grdNewLetterEmails" runat="server" BackColor="White" AutoGenerateColumns="False"
 Width="100%" BorderColor="Gainsboro"
	BorderStyle="Solid" BorderWidth="1px" CellPadding="4" CssClass="Grid" 
        onrowdatabound="grdNewLetterEmails_RowDataBound" 
        onrowcommand="grdNewLetterEmails_RowCommand">
	<AlternatingRowStyle CssClass="labe_content_02" />
	<RowStyle CssClass="labe_content_01" />
	<HeaderStyle CssClass="labe_Caption" Font-Bold="True" HorizontalAlign="Center" />
    <Columns>               
         <asp:TemplateField HeaderText="STT">
         <ItemTemplate><%#Eval("EmailId")%></ItemTemplate>
         </asp:TemplateField>
        <asp:TemplateField  HeaderText="Full Name">            
            <ItemTemplate><%#Eval("FullName")%></ItemTemplate>
        </asp:TemplateField>
        <asp:TemplateField  HeaderText="Email">            
            <ItemTemplate><%#Eval("Email")%></ItemTemplate>
        </asp:TemplateField>
        
         <asp:TemplateField HeaderText="Address">
         <ItemTemplate><%#Eval("Address")%></ItemTemplate>
         </asp:TemplateField>
         <asp:TemplateField HeaderText="Date/Time">
         <ItemTemplate><%#Eval("Date")%></ItemTemplate>
         </asp:TemplateField>
        <asp:TemplateField HeaderText="Sửa" HeaderStyle-Width="20">
            <ItemTemplate>                                                
                <a style="cursor:hand;" href="javascript:void(0)" onclick="javascript:return showPopWinADMIN('/Cms/NewsLetter_Emails/NewsLetter_Emails.aspx?EmailId=<%# Eval("EmailId") %>','Chỉnh Sửa Thông Tin Khách Hàng',500,400,null,__doPostBack)"><img src="../App_Themes/Default/Images/edit.gif" border="0"></a>
            </ItemTemplate>

<HeaderStyle Width="20px"></HeaderStyle>
        </asp:TemplateField>
        <asp:TemplateField HeaderText="Xóa" HeaderStyle-Width="20">
            <ItemTemplate>             
                <asp:Button ID="btnDelete" runat="server" CssClass="Icon_Delete" CommandArgument='<%# Eval("EmailId") %>' CommandName="Commanddelete" OnClientClick="return confirm('Bạn có chắc chắn xóa không ?')" />                   
            </ItemTemplate>

<HeaderStyle Width="20px"></HeaderStyle>
        </asp:TemplateField>
    </Columns>
</asp:GridView>
<table cellspacing="0" cellpadding="0" border="0" width="100%">       
    <tr>
        <td colspan="4" align="center" style="height: 21px">
            <br />            
            <uc1:PagingAjax ID="PagingAjax1" runat="server" />            
            <br />
        </td>
    </tr>
</table> 
</div>